Class ManifestParser

java.lang.Object
edu.claflin.finder.io.ManifestParser

public final class ManifestParser extends Object
Reads manifest files. Assumes that the provided manifest file is correct. This is a static class and requires no instantiation.
Version:
3.1 May 28, 2015
Author:
Charles Allen Schultz II
  • Constructor Details

    • ManifestParser

      private ManifestParser()
      Private constructor for preventing instantiation of the class.
  • Method Details

    • parseManifest

      public static File[] parseManifest(File manifest)
      Parses the provided manifest file.
      Parameters:
      manifest - the File object pointing to the manifest file on disk.
      Returns:
      the File[] array holding the multiple files to be processed.
    • parseManifest

      public static File[] parseManifest(String fileString)
      Parses the provided manifest file. This is a convenience method that allows the programmer to parse a manifest file based on a String representing the location of the file on disk. Assumes the file is correct.
      Parameters:
      fileString - the String representing the manifest file on disk.
      Returns:
      the File[] array holding multiple files to be processed.
    • readManifest

      private static ArrayList<String> readManifest(File manifest)
      Reads the manifest file. This is a helper method that reads the manifest file line by line assuming that each line represents a file to be processed.
      Parameters:
      manifest - the File object pointing to the manifest file on disk.
      Returns:
      the ArrayList containing String objects pointing to graph files.
    • processManifest

      private static File[] processManifest(ArrayList<String> fileStrings)
      Processes the ArrayList of Strings collected by the readManifest() method.
      Parameters:
      fileStrings - the ArrayList of Strings pointing to graphs on the disk.
      Returns:
      the File[] array holding multiple files to be processed.